; Rand2DArray
; -----------
; Returns a 2D array of random data
; Rand2DArray( _
;     $iRows, _       ; Number of rows in the array
;     $aColumns, _    ; Number of columns in the array and data types, see 1) in docu
;     $sSource = "" ) ; Character source for string columns, random strings are created from these characters


; 1) $aColumns parameter
; Five data types are supported: string, integer, float (double), date and time. Strings are created from the
; $sSource character source. Date and time types are created as proper date and time values and are stored as
; 8 and 6 digit integers.
;
; In addition, a "row/col" data type showing row/col index in array elements is supported: A string data type
; on the format "row/col". This data type is valuable during testing and debugging. And it's very fast to cre-
; ate the data. Especially in AutoIt code.
;
; The data types can be abbreviated in this way:
; String:  str, s
; Integer: int, i
; Float:   flo, flt, f
; Date:    dat, dte, d
; Time:    tim, tme, t
; Row/col: r/c, r, c
;
; $aColumns can be specified in three ways:
; 1) As a string: "sifdtr", only one letter abbreviations for the data types can be used
;     Examples:   "sifdtr", 6 columns of strings, integers, floats, dates, times and row/col
;                 "dtsss",  2 columns of dates and times and 3 columns of strings
;                 "ffffff", 6 columns of floats
;
; 2) As a 1D array: [ "s", "i", "f", "d", "t", "r" ], [ "str", "int", "f" ], [ "date", "string" ]
; Purpose of the array is to avoid one letter abbreviations.
;
; 3) As a 2D array:
; Local $aColumns = [ _
;     [ "String",  min, max, duplpct ], _ ; min (0, default   16), max (      1024, default 32)         is length of the strings
;     [ "Integer", min, max, duplpct ], _ ; min (0, default    0), max (2147483647, default $iRows - 1) is size of integers
;     [ "Float",   min, max, duplpct ], _ ; min (0, default    0), max (2147483647, default $iRows - 1) is size of floats
;     [ "Date",    min, max, duplpct ], _ ; min (0, default 2000), max (      9999, default @YEAR)      is year of dates
;     [ "Time",    min, max, duplpct ], _ ; min (0, default    0), max (        23, default 23)         is hour of times
;     [ "Row/col", 0,   0,   0       ] ]  ; min, max and duplpct cannot be specified for row/col columns
;
; Duplpct is the minimum number of duplicates as a percentage. Default is 0% duplicates. However, in the code,
; there is no guarantee that duplicates are not generated. Except for row/col columns that are unique.
;
; Examples:
; Local $aColumns = [ _
;     [ "String",  20,   35,         30 ], _ ; 30% duplicates
;     [ "Integer", 0,    $iRows - 1, 20 ], _ ; 20% duplicates
;     [ "Float",   0,    $iRows - 1, 10 ], _ ; 10% duplicates
;     [ "Date",    2000, 2017 ], _
;     [ "Time",    0,    23   ], _
;     [ "Row/col" ] ]
;
; Local $aColumns = [ _
;     [ "str", 24 ], _ ; Minimum length of strings is 24 characters instead of default 16
;     [ "int" ] ]
